<template>
  <div>
    <ul>
      <li v-for="(val, index) in arr" v-bind:key="index">{{ val }}</li>
      <button @click="btn">走一走</button>
    </ul>
  </div>
</template>

<script>
export default {
  data() {
    return {
      arr: ["帅哥", "美女", "程序员"],
    };
  },
  methods: {
    btn(index) {
      this.arr.push(this.arr[0]);
      this.arr.splice(index, 1);
    },
  },
};
</script>

<style>
</style>